//
// Created by 元穗 on 2017/7/17.
// Copyright (c) 2017 敬信. All rights reserved.
//

public class NetworkConfig {
    var sessionConfig:URLSessionConfiguration?
    fileprivate init() {
    }

    public class func newBuilder() -> NetworkConfigBuilder {
        return NetworkConfigBuilder();
    }
}

public class NetworkConfigBuilder {
    var sessionConfig:URLSessionConfiguration?
    fileprivate init() {
    }
    
    public func sessionConfig(_ config: URLSessionConfiguration) -> Self {
        sessionConfig = config;
        return self;
    }

    public func build() -> NetworkConfig {
        let config = NetworkConfig();
        config.sessionConfig = sessionConfig;
        return config;
    }
}
